IF EXISTS (SELECT * FROM sys.objects WHERE type = 'P' AND name = 'sp_Product_Update_Partner')
	DROP PROCEDURE dbo.sp_Product_Update_Partner
GO
CREATE PROCEDURE dbo.sp_Product_Update_Partner
	@ProductID NVARCHAR(MAX)
	, @PartnerID INT
AS
BEGIN
	SET NOCOUNT OFF

	DECLARE @_ProductID NVARCHAR(MAX)
	DECLARE @_PartnerID INT
	SET @_ProductID = @ProductID 
	SET @_PartnerID = @PartnerID

	UPDATE dbo.Products SET PartnerID = @_PartnerID WHERE EXISTS (SELECT * FROM dbo.fn_SplitString(@ProductID, ','))

	SELECT TOP 1 * FROM dbo.Products WHERE 1 = 2
END
GO